package com.example.ireader;

import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.widget.ImageButton;
import android.widget.Toast;

import com.example.ireader.jie.MainJie;


public class ReadFragment extends Fragment  {



    private static ReadFragment instance;

    // TODO: Rename and change types and number of parameters
    public static ReadFragment getInstance() {
        if (instance==null)
            instance=new ReadFragment();
        return instance;
    }


    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container,
                             Bundle savedInstanceState) {
        // Inflate the layout for this fragment
        View view= inflater.inflate(R.layout.fragment_read, container, false);
        ImageButton imageButton=(ImageButton)view.findViewById(R.id.read_shujia_tianjiabutton);
        imageButton.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                Intent intent =new Intent(getActivity(),MainJie.class);
                startActivity(intent);
            }
        });


        return view;
    }

}
